﻿using System;
using GurLoader.Service.Mailslot;
using NUnit.Framework;

namespace GurLoaderWPF.Test.Service.Mailslot
{
    [TestFixture]
    public class CommandEventArgsTests
    {
        [Test]
        public void CreateInstanceTest()
        {
            const string TestCommand = "MyCommand";
            CommandEventArgs args = new CommandEventArgs(TestCommand);

            Assert.IsNotNull(args);
            Assert.AreEqual(TestCommand, args.Command);
        }

        [Test]
        [ExpectedException(typeof(ArgumentException), ExpectedMessage = "command must not be null.")]
        public void CreateInstanceNullCommandTest()
        {
            CommandEventArgs args = new CommandEventArgs( string.Empty );
        }
    }
}
